﻿////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
// <copyright>Copyright 2008-2011 Andreas Huber Doenni</copyright>
// Distributed under the GNU General Public License version 2 (GPLv2).
// See accompanying file License.txt or copy at http://phuse.codeplex.com/license.
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

namespace Microsoft.Phone.Data.Linq.Mapping
{
    using System;

    /// <summary>See <a href="http://msdn.microsoft.com/en-us/library/microsoft.phone.data.linq.mapping.indexattribute(v=vs.96).aspx">IndexAttribute</a>.</summary>
    /// <remarks>This attribute is currently only available for WP7.1. Adding it to the desktop project allows us to
    /// use the same DB code on both platforms.</remarks>
    [AttributeUsage(AttributeTargets.Class, AllowMultiple = true, Inherited = false)]
    internal sealed class IndexAttribute : Attribute
    {
        /// <summary>See link in summary.</summary>
        public string Columns { get; set; }

        /// <summary>See link in summary.</summary>
        public bool IsUnique { get; set; }

        /// <summary>See link in summary.</summary>
        public string Name { get; set; }
    }
}
